using System;
using UnityEngine;

[Serializable]
public class flypaper : MonoBehaviour
{
	public int times;

	public void OnCollisionEnter(Collision col)
	{
		if ((bool)col.rigidbody)
		{
			col.rigidbody.isKinematic = true;
		}
		if (col.collider.tag == "AI")
		{
			times++;
			if (times >= 15)
			{
				JCAchievementMunger.UnlockAchievement("CgkI3_DHnsgeEAIQEQ");
			}
		}
		if (col.collider.tag == "Player")
		{
			PlayerPrefs.SetInt("FallenOut", PlayerPrefs.GetInt("FallenOut") + 1);
			if (PlayerPrefs.GetInt("FallenOut") >= 10)
			{
				JCAchievementMunger.UnlockAchievement("CgkI3_DHnsgeEAIQDw");
			}
		}
	}

	public void Main()
	{
	}
}
